
******************************************************
***************** TABLE A.6 *******************

use "${ddata}cleaned_data_wACSweight.dta", clear

foreach var of varlist donation_fo donation_so donation_so_l_fo {  

	sum `var' if control == 1 [aweight=weight_ACS]
	local mean_`var' = string(`r(mean)', "%10.2fc")
	local sd_`var'   = string(`r(sd)', "%10.2fc")

	sum `var' if control == 1 & male == 1  [aweight=weight_ACS]
	local mean_`var'_male = string(`r(mean)', "%10.2fc")
	local sd_`var'_male   = string(`r(sd)', "%10.2fc")

	sum `var' if control == 1 & male == 0  [aweight=weight_ACS] 
	local mean_`var'_female = string(`r(mean)', "%10.2fc")
	local sd_`var'_female   = string(`r(sd)', "%10.2fc")

}

local lbl_donation_fo      = "First-Order Beliefs (FO)"
local lbl_donation_so      = "Second-Order Beliefs (SO)"
local lbl_donation_so_l_fo = "Share FO $<$ SO"

texdoc init "${o}TableA6_weighted_final.tex", replace force
tex \begin{tabular}{lcccc} 
tex \toprule
tex \multicolumn{4}{c}{Share of \textdollar100 would donate to support working women} \\
tex \midrule
tex & Overall & Men & Women  \\
foreach var of varlist donation_fo donation_so {  
	tex `lbl_`var'' & `mean_`var'' & `mean_`var'_male' & `mean_`var'_female' \\
	tex             & (`sd_`var'') & (`sd_`var'_male') & (`sd_`var'_female') \\

}
foreach var of varlist  donation_so_l_fo{  
	tex `lbl_`var'' & `mean_`var'' & `mean_`var'_male' & `mean_`var'_female' \\

}

tex \bottomrule
tex \end{tabular}

texdoc close


